﻿@model IEnumerable<Weibo4Sharp.Model.WeiboUser>
<div id="fans">
    @foreach (var fan in Model)
    {
        <div>
            @Html.Partial("_WeiboHeadPic", fan)
            <div class="weibo-right">
                <div>
                    @Html.Partial("_WeiboUserName", fan)
                    <div>
                        location: @fan.Location
                    </div>
                    <div>
                        following: @fan.FriendsCount
                        fans: @fan.FollowersCount
                        weibos: @fan.StatusesCount
                    </div>
                </div>
            </div>
            <div style="clear: both">
            </div>
            <div class="hr">
            </div>
        </div>
}
    @{ var ajaxOption = new AjaxOptions { 
           HttpMethod = "GET", 
           UpdateTargetId = "fans", 
           InsertionMode = InsertionMode.Replace,
           OnBegin = "onListFansBegin",
           OnSuccess = "onListFanSuccess",
           OnFailure = "onListFanFailure"
       };
     }
    <div class="mt4">
        @if (ViewBag.Prev != null)
{
            @Ajax.ActionLink("<< Prev ", "Fans", new { id = ViewBag.Prev}, ajaxOption)
}
        @if(ViewBag.Next != null)
{
            @Ajax.ActionLink(" Next >>", "Fans", new { id = ViewBag.Next}, ajaxOption)
}
    </div>
</div>


